home *** CD-ROM | disk | FTP | other *** search
/ Amiga Tools 2 / Amiga Tools 2.iso / libs / garshnelib / garshnelib.h < prev    next >
C/C++ Source or Header  |  1995-03-09  |  1KB  |  67 lines

  1. #ifndef INTERFACE_H
  2. #define INTERFACE_H
  3.  
  4. #include <graphics/text.h>
  5.  
  6. typedef struct _IfcObject
  7. {
  8.     LONG io_Type;
  9.     STRPTR io_Label;
  10.     STRPTR io_Char;
  11.     STRPTR *io_Labels;
  12.     LONG io_Active;
  13.     LONG io_Min;
  14.     LONG io_Max;
  15.     LONG io_Level;
  16.     struct TextAttr io_Attr;
  17.     STRPTR io_Value;
  18. }
  19. IfcObject;
  20.  
  21. typedef struct _PrefObject
  22. {
  23.     LONG po_Type;
  24.     union
  25.     {
  26.         LONG pou_Active;
  27.         LONG pou_Level;
  28.         struct TextAttr pou_Attr;
  29.         BYTE pou_Value[128];
  30.         struct
  31.         {
  32.             LONG pod_ModeID;
  33.             LONG pod_Depth;
  34.         }
  35.         pou_Display;
  36.     }
  37.     po_Union;
  38. }
  39. PrefObject;
  40.  
  41. #define po_Active po_Union.pou_Active
  42. #define po_Level  po_Union.pou_Level
  43. #define po_Attr   po_Union.pou_Attr
  44. #define po_Value  po_Union.pou_Value
  45. #define po_ModeID po_Union.pou_Display.pod_ModeID
  46. #define po_Depth  po_Union.pou_Display.pod_Depth
  47.  
  48. #define GAD_CYCLE   1
  49. #define GAD_SLIDER  2
  50. #define GAD_FONT    3
  51. #define GAD_STRING  4
  52. #define GAD_DISPLAY 5
  53. #define GAD_DELIM   6
  54.  
  55. #define ID_SAVE    7
  56. #define ID_TEST    8
  57. #define ID_CANCEL  9
  58.  
  59. #define CastAndShift( x ) (( SPFix( SPMul( x, SPFlt( Colors )))) << Shift )
  60. #define PREFSIZE ( sizeof( PrefObject ) * 20 )
  61.  
  62. #define PREF_OK   0
  63. #define PREF_TEST 1
  64. #define PREF_ERR  2
  65.  
  66. #endif /* INTERFACE_H */
  67.